package com.atguigu.multiReading;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

public class demo5 {
    //线程池的使用较为简单，使用submit方法即可
    public static void main(String[] args) {
        ExecutorService pool= Executors.newCachedThreadPool();
        pool.submit(new Runnable() {
            @Override
            public void run() {
                System.out.println("这是任务");
            }
        });
    }
}
